﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web.UI.WebControls;
using System.Web.UI;
using Microsoft.SharePoint;

namespace Srs.Sample.UI.WebParts
{
    public class ProgressTemplate : ITemplate
    {

        public void InstantiateIn(Control container)
        {
            Label lbl = new Label();
            lbl.Text = "Progress......";

            Image img = new Image();
            img.ImageUrl = SPContext.Current.Site.Url + "/Images1/progress.gif";

            container.Controls.Add(lbl);
            container.Controls.Add(img);
        }

    }





    ////Testing
    //public class SimpleProgressTemplate : ITemplate
    //{
    //    public string ImagePath { get; set; }
    //    public string DisplayText { get; set; }

    //    public SimpleProgressTemplate(string imagePath, string displayText)
    //    {
    //        ImagePath = imagePath;
    //        DisplayText = displayText;
    //    }

    //    public void InstantiateIn(Control container)
    //    {
    //        Image img = new Image();
    //        img.ImageUrl = SPContext.Current.Site.Url + "/" + ImagePath;

    //        Label lbl = new Label();
    //        lbl.Text = DisplayText;

    //        container.Controls.Add(img);
    //        container.Controls.Add(lbl);
    //    }
    //} 

}
